import Vue from "vue";
import VueRouter from "vue-router";

Vue.use(VueRouter)
const main = () => import('../src/components/product')
const register = ()=>import('../src/components/content/register/register')
const info = ()=>import('../src/components/content/info/info')
const profile =()=>import('../src/components/content/profile/profile')
const detail =()=>import('../src/components/content/detail/detail')
const set = ()=>import('../src/components/content/set/set')
const all =()=>import('../src/components/content/all/all')
const change =()=>import('../src/components/content/change/change')
const routes = [
  {
    path: '',
    redirect: '/main'
  },
  {
    path: '/main',
    component: main
  },
  {
    path: '/change',
    component: change
  },
  {
    path: '/register',
    component:register
  },
  {
    path: '/all',
    component:all
  },
  {
    path: '/info',
    component:info
  },
  {
    path: '/profile',
    component:profile
  },
  {
    path: '/set',
    component:set
  },
  {
    path: '/detail',
    component:detail
  }
]
const router = new VueRouter({
  routes,
  mode: 'hash'
})

export default router
